package testes;

import static org.junit.Assert.*;

import java.util.HashSet;
import java.util.Set;

import org.bunny.businessLayer.Continente;
import org.bunny.businessLayer.Pais;
import org.junit.After;
import org.junit.AfterClass;
import org.junit.Before;
import org.junit.BeforeClass;
import org.junit.Test;

public class ContinenteTest {

	@BeforeClass
	public static void setUpBeforeClass() throws Exception {
	}

	@AfterClass
	public static void tearDownAfterClass() throws Exception {
	}

	@Before
	public void setUp() throws Exception {
	}

	@After
	public void tearDown() throws Exception {
	}

	

	@Test
	public void testContinenteString() {
		Continente eu = new Continente("Europa");
		
		eu.setNome("Africa");
		assertEquals("Africa",eu.nome());
		
		Set<Pais> paises = new HashSet<Pais>();
		Pais a = new Pais();
		Pais b = new Pais();
		paises.add(b);
		
		eu.setPaises(paises);
		assertEquals(paises,eu.paises());

	}

	@Test
	public void testToString() {
		Continente eu = new Continente("Europa");
		assertEquals("Continente [nome=" + "Europa" + "]\n",eu.toString());
	}

}
